export const BleController = {
	/**
	 * 蓝牙连接状态
	 */
	addConnectStateListen(callBack) {
		this.public.bleConnectStateCallBack = callBack
	},
	/**
	 * 传输数据监听
	 */
	addTransferDataListen(callBack) {
		this.public.bleProgressDataCallBack = callBack
	},
	// 连接状态
	connectStateListen(params) {
		if (this.public.bleConnectStateCallBack) {
			this.public.bleConnectStateCallBack(params)
		}
	},
	// 数据传输中
	transferDataListen(params) {
		if (this.public.bleTransferDataCallBack) {
			this.public.bleTransferDataCallBack(params)
		}
	},

	public: {
		bleConnectStateCallBack: null,
		bleTransferDataCallBack: null,
	}
}
